home *** CD-ROM | disk | FTP | other *** search
/ Amiga Plus 2004 #9 / Amiga Plus CD - 2004 - No. 09.iso / amigaplus / tools / amigaos4_only / ifxlite / imagefx3 / rexx / autofx / renameoneforsequence.ifx.pre < prev    next >
Text File  |  2004-08-03  |  823b  |  40 lines

  1. /*
  2.  * RenameForSequence.ifx.pre
  3.  * Written by Thomas Krehbiel
  4.  *
  5.  * Rename frames into sequential numbers.
  6.  *
  7.  * Inputs:
  8.  *    Word(Arg(1),1) = Sequence number
  9.  *    Word(Arg(1),2) = Total number of frames (N)
  10.  *
  11.  * Returns:
  12.  *    0 if successful, non-zero on failure
  13.  *
  14.  */
  15.  
  16. OPTIONS RESULTS
  17.  
  18. base     = 'Autofx_RenameOneSeq_'
  19.  
  20. basedir  = GETCLIP(base||'BaseDir')
  21. basefile = GETCLIP(base||'BaseFile')
  22. num      = GETCLIP(base||'Count')
  23.  
  24. IF num = "" THEN num = 30
  25.  
  26. RequestFile '"Sequence Basename:"' '"'basedir'"' '"'basefile'"'
  27. IF rc ~= 0 THEN EXIT rc
  28. basename = result
  29.  
  30. RequestNumber '"Number of frames to create:"' num
  31. IF rc ~= 0 THEN EXIT rc
  32. num = result
  33.  
  34. CALL SETCLIP(base||'BaseDir', filereq.path)
  35. CALL SETCLIP(base||'BaseFile', filereq.file)
  36. CALL SETCLIP(base||'Base', basename)
  37. CALL SETCLIP(base||'Count', num)
  38.  
  39. EXIT
  40.